import pymongo
from icecream import ic

client = pymongo.MongoClient()
db = client['python']['jaoben']
filter = {}
keyword = "Python实现对照片中的人脸进行颜值预测"
condition ={}
condition['$regex'] =keyword
filter["标题"] = condition
print(filter)
res = db.find(filter)
print(res.count())
for i in res:
    ic(i['标题'])
# print(res.count())
# db.remove(filter)
# data = db.find({'标题': {'$regex':'lelenium'}})
# print(data)
# print(data.count())
# for i in data:
#     print(i['标题'])



